/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package alcatelparser.tags;

import alcatelparser.modules.BuilderFactory;
import alcatelparser.modules.Env;
import alcatelparser.modules.I;

/**
 *
 * @author geniuz
 */
public abstract class MarketSpecificRecordsTypeTag extends DefaultParserTag
{

    public MarketSpecificRecordsTypeTag()
    {
    }

    public void parseTag(int ai[], int i)
    {
        setNotParseRecordLength(ai, i);
        _array = ai;
        _startParsePosition = i;
        if(Env.getEnv().isFullForm())
            BuilderFactory.getBuilder().writeTagContent(2, 0, getTagValue(), getParsedContent());
        else
        if(isTagChecked(I.I(1375)))
        {
            String s = toHex(0);
            if(Env.getEnv().isFieldsDecoding())
                s = getTagValue();
            BuilderFactory.getBuilder().writeTagContent(1, 0, getReducedTagPropertiesValue(I.I(1386)), s);
        }
    }

    public abstract String getTagValue();

    public String getParseIdentityTag()
    {
        return "";
    }

    public boolean isChoiceTag()
    {
        return true;
    }
}
